#include <stdio.h>
#include <math.h>

struct mapnode {
	double wn;
	double w;
	double ws;
	double s;
	double es;
	double e;
	double en;
	double n;
};

int main() {
	int m, n;
	while (scanf("%d %d", &m, &n) != EOF) {
		mapnode map[m][n];
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < n; j++) {
				double wn = sqrt(2);
				double w = 1;
				double ws = sqrt(2);
				double s = 1;
				double es = sqrt(2);
				double e = 1;
				double en = sqrt(2);
				double n = 1;

			}
		}

	}
	return 0;
}